from myPsychology.odmantic.mongoDB_models import Scale
from myPsychology.scoring import scale_scoring as scoring
from myPsychology.utility.enums import Gender, Profession


def scoring_the_scale(the_scale: Scale, the_answers: dict) -> dict:
    answers = the_answers['answers']
    the_scale = the_scale.model_dump()
    scores = {}
    scores['量表名称'] = the_scale['chinese_name']
    scores['量表英文缩写'] = the_scale['abbreviation']

    infos = {}

    # AAQ_II
    if the_scale['abbreviation'] == 'AAQ_II':
        infos['the_scores'] = scoring.scoring_AAQ_II(the_scale, answers)
        from myPsychology.analyzing import analyzing_AAQ_II as AAQ_II
        result = AAQ_II.analyzing_AAQ_II(infos)
        scores['总分'] = result['total_score']
        scores['最高分'] = result['score_max']
        scores['各条目分'] = result['items_scores']

    # AAS_R
    if the_scale['abbreviation'] == 'AAS_R':
        infos['the_scores'] = scoring.scoring_AAS_R(the_scale, answers)
        infos['scales_items'] = the_scale['contents']['scales_items']
        from myPsychology.analyzing import analyzing_AAS_R as AAS_R
        result = AAS_R.analyzing_AAS_R(infos)
        scores['各维度平均值'] = result['scales_scores_mean']

    # ABC
    if the_scale['abbreviation'] == 'ABC':
        infos['the_scores'] = scoring.scoring_ABC(the_scale, answers)
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['scales_loads'] = the_scale['contents']['scales_loads']
        from myPsychology.analyzing import analyzing_ABC as ABC
        result = ABC.analyzing_ABC(infos)
        scores['总分'] = result['total_score']
        scores['各维度分数'] = result['scales_scores']
        scores['各维度最高分'] = result['max_scores']
        scores['解释'] = result['interpreter']

    # AIASS
    if the_scale['abbreviation'] == 'AIASS':
        infos['the_scores'] = scoring.scoring_AIASS(the_scale, answers)
        from myPsychology.analyzing import analyzing_AIASS as AIASS
        result = AIASS.analyzing_AIASS(infos)
        scores['总分'] = result['total_score']
        scores['最高分'] = result['score_max']
        scores['各维度分数'] = result['scales_scores']

    # ALBS
    if the_scale['abbreviation'] == 'ALBS':
        infos['the_scores'] = scoring.scoring_ALBS(the_scale, answers)
        from myPsychology.analyzing import analyzing_ALBS as ALBS
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        result = ALBS.analyzing_ALBS(infos)
        scores['总分'] = result['total_score']
        scores['最高分'] = result['score_max']
        scores['各维度分数'] = result['scales_scores']
        scores['各维度最高分'] = result['scales_scores_max']

    # API
    if the_scale['abbreviation'] == 'API':
        infos['the_scores'] = scoring.scoring_API(the_scale, answers)
        from myPsychology.analyzing import analyzing_API as API
        result = API.analyzing_API(infos)
        scores['总分'] = result['total_score']
        scores['最高分'] = result['score_max']

    # APIUS
    if the_scale['abbreviation'] == 'APIUS':
        infos['the_scores'] = scoring.scoring_APIUS(the_scale, answers)
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        from myPsychology.analyzing import analyzing_APIUS as APIUS
        result = APIUS.analyzing_APIUS(infos)
        scores['总分'] = result['total_score']
        scores['总分均值'] = result['total_score_mean']
        scores['最高分'] = result['score_max']
        scores['各维度分数'] = result['scales_scores']
        scores['各维度最高分'] = result['scales_scores_max']

    # ASAS
    if the_scale['abbreviation'] == 'ASAS':
        infos['the_scores'] = scoring.scoring_ASAS(the_scale, answers)
        from myPsychology.analyzing import analyzing_ASAS as ASAS
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        infos['factors_scales'] = the_scale['contents']['factors_scales']
        infos['lie_detect_items'] = the_scale['contents']['lie_detect_items']
        result = ASAS.analyzing_ASAS(infos)
        scores['测谎题（回答不一致，对）'] = result['lies_count']
        scores['总分'] = result['total_scores']
        scores['总分均值'] = round(result['total_scores_mean'], 4)
        scores['各维度分数'] = result['scales_scores']
        scores['各因子分数'] = result['factors_scores']
        scores['最低分'] = result['score_min']
        scores['最高分'] = result['score_max']
        scores['各维度最高分数'] = result['scales_scores_max']
        scores['各因子最高分数'] = result['factors_scores_max']

    # ASLSS
    if the_scale['abbreviation'] == 'ASLSS':
        infos['the_scores'] = scoring.scoring_ASLSS(the_scale, answers)
        from myPsychology.analyzing import analyzing_ASLSS as ASLSS
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        result = ASLSS.analyzing_ASLSS(infos)
        scores['总分'] = result['total_score']
        scores['各维度分数'] = result['scales_scores']
        scores['最高分'] = result['score_max']
        scores['各维度最高分数'] = result['scales_scores_max']

    # ASMHS
    if the_scale['abbreviation'] == 'ASMHS':
        infos['the_scores'] = scoring.scoring_ASMHS(the_scale, answers)
        from myPsychology.analyzing import analyzing_ASMHS as ASMHS
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        infos['factors_scales'] = the_scale['contents']['factors_scales']
        infos['lie_detect_items'] = the_scale['contents']['lie_detect_items']
        result = ASMHS.analyzing_ASMHS(infos)
        scores['测谎题（回答不一致，对）'] = result['lies_count']
        scores['总分'] = result['total_scores']
        scores['各维度分数'] = result['scales_scores']
        scores['各因子分数'] = result['factors_scores']
        scores['最低分'] = result['score_min']
        scores['最高分'] = result['score_max']
        scores['各维度最高分数'] = result['scales_scores_max']
        scores['各因子最高分数'] = result['factors_scores_max']

    # ASQ
    if the_scale['abbreviation'] == 'ASQ':
        infos['the_scores'] = scoring.scoring_ASQ(the_scale, answers)
        from myPsychology.analyzing import analyzing_ASQ as ASQ
        result = ASQ.analyzing_ASQ(infos)
        scores['总分'] = round(result['total_scores'], 4)
        scores['各维度分数'] = result['scales_scores']

    # ASSIST
    if the_scale['abbreviation'] == 'ASSIST':
        infos['the_scores'] = scoring.scoring_ASSIST(the_scale, answers)
        from myPsychology.analyzing import analyzing_ASSIST as ASSIST
        result = ASSIST.analyzing_ASSIST(infos)
        scores['各物质依赖条目分数'] = result['scores']
        scores['各物质依赖分数'] = result['substances_scores']
        scores['各物质依赖最高分数'] = result['substances_scores_max']
        scores['注射分数'] = result['injection_score']
        scores['各物质依赖干预类型'] = result['intervene']

    # ASSRS
    if the_scale['abbreviation'] == 'ASSRS':
        infos['the_scores'] = scoring.scoring_ASSRS(the_scale, answers)
        from myPsychology.analyzing import analyzing_ASSRS as ASSRS
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        result = ASSRS.analyzing_ASSRS(infos)
        scores['总分'] = result['total_score']
        scores['各维度分数'] = result['scales_scores']
        scores['最高分'] = result['score_max']
        scores['各维度最高分数'] = result['scales_scores_max']

    # BDI
    if the_scale['abbreviation'] == 'BDI':
        infos['the_scores'] = scoring.scoring_BDI(the_scale, answers)
        from myPsychology.analyzing import analyzing_BDI as BDI
        result = BDI.analyzing_BDI(infos)
        scores['总分'] = result['total_score']
        scores['最高分'] = result['score_max']

    # BEHAVE_AD
    if the_scale['abbreviation'] == 'BEHAVE_AD':
        infos['the_scores'] = scoring.scoring_BEHAVE_AD(the_scale, answers)
        from myPsychology.analyzing import analyzing_BEHAVE_AD as BEHAVE_AD
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        result = BEHAVE_AD.analyzing_BEHAVE_AD(infos)
        scores['总分'] = result['total_score']
        scores['各维度分数'] = result['scales_scores']
        scores['最高分'] = result['score_max']
        scores['各维度最高分数'] = result['scales_scores_max']

    # BFFP_CAS_B
    if the_scale['abbreviation'] == 'BFFP_CAS_B':
        infos['the_scores'] = scoring.scoring_BFFP_CAS_B(the_scale, answers)
        from myPsychology.analyzing import analyzing_BFFP_CAS_B as BFFP_CAS_B
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        result = BFFP_CAS_B.analyzing_BFFP_CAS_B(infos)
        scores['总分'] = result['total_score']
        scores['各维度分数'] = result['scales_scores']
        scores['最高分'] = result['score_max']
        scores['各维度最高分数'] = result['scales_scores_max']

    # BPRS
    if the_scale['abbreviation'] == 'BPRS':
        infos['the_scores'] = scoring.scoring_BPRS(the_scale, answers)
        from myPsychology.analyzing import analyzing_BPRS as BPRS
        infos['items'] = the_scale['contents']['items']
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        result = BPRS.analyzing_BPRS(infos)
        scores['总分'] = result['total_score']
        scores['各条目症状'] = result['symptoms']
        scores['各条目分数'] = result['items_scores']
        scores['各维度分数'] = result['scales_scores']
        scores['最高分'] = result['score_max']
        scores['各维度最高分数'] = result['scales_scores_max']

    # BRMS
    if the_scale['abbreviation'] == 'BRMS':
        infos['the_scores'] = scoring.scoring_BRMS(the_scale, answers)
        from myPsychology.analyzing import analyzing_BRMS as BRMS
        result = BRMS.analyzing_BRMS(infos)
        scores['总分_1'] = result['total_scores_1']
        scores['总分_2'] = result['total_scores_2']
        scores['最高分'] = result['score_max']

    # BRUMS_C
    if the_scale['abbreviation'] == 'BRUMS_C':
        infos['the_scores'] = scoring.scoring_BRUMS_C(the_scale, answers)
        from myPsychology.analyzing import analyzing_BRUMS_C as BRUMS_C
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        result = BRUMS_C.analyzing_BRUMS_C(infos)
        scores['总分'] = result['total_score']
        scores['各维度分数'] = result['scales_scores']
        scores['最高分'] = result['score_max']
        scores['各维度最高分数'] = result['scales_scores_max']

    # CABS
    if the_scale['abbreviation'] == 'CABS':
        infos['the_scores'] = scoring.scoring_CABS(the_scale, answers)
        from myPsychology.analyzing import analyzing_CABS as CABS
        result = CABS.analyzing_CABS(infos)
        scores['各条目分数'] = result['items_scores']
        scores['总分'] = result['total_score']
        scores['最高分'] = result['score_max']
        scores['从不，计数'] = result['count_min']
        scores['经常，计数'] = result['count_mmax']

    # CARS
    if the_scale['abbreviation'] == 'CARS':
        infos['the_scores'] = scoring.scoring_CARS(the_scale, answers)
        from myPsychology.analyzing import analyzing_CARS as CARS
        infos['items'] = the_scale['contents']['items']
        result = CARS.analyzing_CARS(infos)
        scores['条目'] = result['items']
        scores['条目分数'] = result['items_scores']
        scores['总分'] = result['total_score']
        scores['最高分'] = result['score_max']

    # Catell_16PF
    if the_scale['abbreviation'] == 'Catell_16PF':
        infos['the_scores'] = scoring.scoring_Catell_16PF(the_scale, answers)
        from myPsychology.analyzing import analyzing_Catell_16PF as Catell_16PF
        if the_answers['gender'] == Gender.MALE:
            infos['gender'] = Gender.MALE.name
        else:
            infos['gender'] = Gender.FEMALE.name
        result = Catell_16PF.analyzing_Catell_16PF(infos)
        scores['16种人格因素分数'] = result['scales_scores_16PF']
        scores['解释'] = result['interpreter']

    # CBCL
    if the_scale['abbreviation'] == 'CBCL':
        sub_scales = the_scale['contents']
        infos['the_scores'] = scoring.scoring_CBCL(sub_scales, answers)
        from myPsychology.analyzing import analyzing_CBCL as CBCL
        infos['sub_scales'] = sub_scales
        infos['answers'] = answers
        result = CBCL.analyzing_CBCL(infos)
        scores['社会能力'] = result['factors_scores']['social_ability']
        scores['行为问题'] = result['behavior_scale']

    # CBF_PI_B
    if the_scale['abbreviation'] == 'CBF_PI_B':
        infos['the_scores'] = scoring.scoring_CBF_PI_B(the_scale, answers)
        from myPsychology.analyzing import analyzing_CBF_PI_B as CBF_PI_B
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        result = CBF_PI_B.analyzing_CBF_PI_B(infos)
        scores['各维度分数'] = result['scales_scores']
        scores['各维度最高分数'] = result['scales_scores_max']

    # CBI_PSCP
    if the_scale['abbreviation'] == 'CBI_PSCP':
        infos['the_scores'] = scoring.scoring_CBI_PSCP(the_scale, answers)
        from myPsychology.analyzing import analyzing_CBI_PSCP as CBI_PSCP
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        result = CBI_PSCP.analyzing_CBI_PSCP(infos)
        scores['各维度分数'] = result['scales_scores']
        scores['各维度最高分数'] = result['scales_scores_max']

    # CES_D
    if the_scale['abbreviation'] == 'CES_D':
        infos['the_scores'] = scoring.scoring_CES_D(the_scale, answers)
        from myPsychology.analyzing import analyzing_CES_D as CES_D
        result = CES_D.analyzing_CES_D(infos)
        scores['总分'] = result['total_score']
        scores['最高分'] = result['score_max']

    # CFMPS
    if the_scale['abbreviation'] == 'CFMPS':
        infos['the_scores'] = scoring.scoring_CFMPS(the_scale, answers)
        from myPsychology.analyzing import analyzing_CFMPS as CFMPS
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        infos['factors_scales'] = the_scale['contents']['factors_scales']
        result = CFMPS.analyzing_CFMPS(infos)
        scores['总分'] = result['total_scores']
        scores['各维度分数'] = result['scales_scores']
        scores['各因子分数'] = result['factors_scores']
        scores['最高分'] = result['score_max']
        scores['各维度最高分数'] = result['scales_scores_max']
        scores['各因子最高分数'] = result['factors_scores_max']
        scores['参考百分位'] = result['percentile']

    # CLS
    if the_scale['abbreviation'] == 'CLS':
        infos['the_scores'] = scoring.scoring_CLS(the_scale, answers)
        from myPsychology.analyzing import analyzing_CLS as CLS
        infos['insert_items'] = the_scale['contents']['insert_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        result = CLS.analyzing_CLS(infos)
        scores['总分'] = result['total_score']
        scores['最高分'] = result['score_max']

    # CMI
    if the_scale['abbreviation'] == 'CMI':
        infos['the_scores'] = scoring.scoring_CMI(the_scale, answers)
        from myPsychology.analyzing import analyzing_CMI as CMI
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        result = CMI.analyzing_CMI(infos)
        scores['总分'] = result['total_scores']
        scores['M-R总分'] = result['scores_M_R']
        scores['各维度分数'] = result['scales_scores']
        scores['最高分'] = result['score_max']
        scores['M-R最高分'] = result['scores_max_M_R']
        scores['各维度最高分数'] = result['scales_scores_max']

    # CMLQ
    if the_scale['abbreviation'] == 'CMLQ':
        infos['the_scores'] = scoring.scoring_CMLQ(the_scale, answers)
        from myPsychology.analyzing import analyzing_CMLQ as CMLQ
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        result = CMLQ.analyzing_CMLQ(infos)
        scores['总分'] = result['total_scores']
        scores['各维度分数'] = result['scales_scores']
        scores['最高分'] = result['score_max']
        scores['各维度最高分数'] = result['scales_scores_max']

    # CMQI
    if the_scale['abbreviation'] == 'CMQI':
        infos['the_scores'] = scoring.scoring_CMQI(the_scale, answers)
        from myPsychology.analyzing import analyzing_CMQI as CMQI
        if the_answers['gender'] == Gender.MALE:
            infos['gender'] = Gender.MALE.value
        else:
            infos['gender'] = Gender.FEMALE.value
        infos['age'] = the_answers['age']
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        result = CMQI.analyzing_CMQI(infos)
        scores['总分'] = result['total_scores']
        scores['各维度分数'] = result['scales_scores']
        scores['总分T值'] = result['T_total_scores']
        scores['总分百分位'] = result['P_total_scores']
        scores['各维度分数T值'] = result['T_scales_scores']
        scores['各维度分数百分位'] = result['P_scales_scores']
        scores['最高分'] = result['score_max']
        scores['各维度最高分数'] = result['scales_scores_max']

    # CSES
    if the_scale['abbreviation'] == 'CSES':
        infos['the_scores'] = scoring.scoring_CSES(the_scale, answers)
        from myPsychology.analyzing import analyzing_CSES as CSES
        if the_answers['gender'] == Gender.MALE:
            infos['gender'] = Gender.MALE.value
        else:
            infos['gender'] = Gender.FEMALE.value
        if the_answers['profession'] == Profession.EMPLOYEE:
            infos['profession'] = Profession.EMPLOYEE.value
        else:
            infos['profession'] = Profession.COLLEGE.value
        result = CSES.analyzing_CSES(infos)
        scores['总分'] = result['total_score']
        scores['总分百分位'] = result['percent']
        scores['最高分'] = result['score_max']

    # CSQ
    if the_scale['abbreviation'] == 'CSQ':
        infos['the_scores'] = scoring.scoring_CSQ(the_scale, answers)
        from myPsychology.analyzing import analyzing_CSQ as CSQ
        infos['score_rules'] = the_scale['contents']['score_rules']
        result = CSQ.analyzing_CSQ(infos)
        scores['各维度分数'] = result['scales_scores']
        scores['各因子分数'] = result['factors_scores']
        scores['各维度最高分数'] = result['scales_scores_max']
        scores['各因子最高分数'] = result['factors_scores_max']

    # DCCC
    if the_scale['abbreviation'] == 'DCCC':
        infos['the_scores'] = scoring.scoring_DCCC(the_scale, answers)
        from myPsychology.analyzing import analyzing_DCCC as DCCC
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        result = DCCC.analyzing_DCCC(infos)
        scores['总分'] = result['total_scores']
        scores['各维度分数'] = result['scales_scores']
        scores['最高分'] = result['score_max']
        scores['各维度最高分数'] = result['scales_scores_max']

    # DEQ
    if the_scale['abbreviation'] == 'DEQ':
        infos['the_scores'] = scoring.scoring_DEQ(the_scale, answers)
        from myPsychology.analyzing import analyzing_DEQ as DEQ
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        result = DEQ.analyzing_DEQ(infos)
        scores['总分'] = result['total_scores']
        scores['各维度分数'] = result['scales_scores']
        scores['最高分'] = result['score_max']
        scores['各维度最高分数'] = result['scales_scores_max']

    # DES_II
    if the_scale['abbreviation'] == 'DES_II':
        infos['the_scores'] = scoring.scoring_DES_II(the_scale, answers)
        from myPsychology.analyzing import analyzing_DES_II as DES_II
        result = DES_II.analyzing_DES_II(infos)
        scores['总分'] = result['total_scores']
        scores['总分均值'] = result['total_scores_mean']
        scores['最高分'] = result['score_max']

    # DSRSC
    if the_scale['abbreviation'] == 'DSRSC':
        infos['the_scores'] = scoring.scoring_DSRSC(the_scale, answers)
        from myPsychology.analyzing import analyzing_DSRSC as DSRSC
        result = DSRSC.analyzing_DSRSC(infos)
        scores['总分'] = result['total_scores']
        scores['最高分'] = result['score_max']

    # DSS correction
    if the_scale['abbreviation'] == 'DSS':
        infos['the_scores'] = scoring.scoring_DSS(the_scale, answers)
        from myPsychology.analyzing import analyzing_DSS as DSS
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        infos['symptoms'] = the_scale['contents']['symptoms']
        result = DSS.analyzing_DSS(infos)
        scores['总分'] = result['total_scores']
        scores['各症状分数'] = result['items_scores']
        scores['症状'] = result['symptoms']
        scores['各维度分数'] = result['scales_scores']
        scores['最高分'] = result['score_max']
        scores['各维度最高分数'] = result['scales_scores_max']

    # EMBU
    if the_scale['abbreviation'] == 'EMBU':
        infos['the_scores'] = scoring.scoring_EMBU(the_scale, answers)
        from myPsychology.analyzing import analyzing_EMBU as EMBU
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        infos['factors_scales'] = the_scale['contents']['factors_scales']
        result = EMBU.analyzing_EMBU(infos)
        scores['各维度分数'] = result['scales_scores']
        scores['各因子分数'] = result['factors_scores']
        scores['各维度最高分数'] = result['scales_scores_max']
        scores['各因子最高分数'] = result['factors_scores_max']

    # EMP
    if the_scale['abbreviation'] == 'EMP':
        infos['the_scores'] = scoring.scoring_EMP(the_scale, answers)
        from myPsychology.analyzing import analyzing_EMP as EMP
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        result = EMP.analyzing_EMP(infos)
        scores['总分'] = result['total_scores']
        scores['最高分'] = result['score_max']
        scores['各维度分数'] = result['scales_scores']
        scores['各维度最高分数'] = result['scales_scores_max']

    # EPDS
    if the_scale['abbreviation'] == 'EPDS':
        infos['the_scores'] = scoring.scoring_EPDS(the_scale, answers)
        from myPsychology.analyzing import analyzing_EPDS as EPDS
        result = EPDS.analyzing_EPDS(infos)
        scores['总分'] = result['total_scores']
        scores['最高分'] = result['score_max']

    # EPQ
    if the_scale['abbreviation'] == 'EPQ':
        infos['the_scores'] = scoring.scoring_EPQ(the_scale, answers)
        from myPsychology.analyzing import analyzing_EPQ as EPQ
        if the_answers['gender'] == Gender.MALE:
            infos['gender'] = Gender.MALE.value
        else:
            infos['gender'] = Gender.FEMALE.value
        infos['age'] = the_answers['age']
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        result = EPQ.analyzing_EPQ(infos)
        scores['总分'] = result['total_scores']
        scores['各维度分数'] = result['scales_scores']
        scores['各维度分数T值'] = result['T_scales_scores']
        scores['最高分'] = result['score_max']
        scores['各维度最高分数'] = result['scales_scores_max']

    # EQ
    if the_scale['abbreviation'] == 'EQ':
        infos['the_scores'] = scoring.scoring_EQ(the_scale, answers)
        from myPsychology.analyzing import analyzing_EQ as EQ
        result = EQ.analyzing_EQ(infos)
        scores['总分'] = result['total_scores']
        scores['最高分'] = result['score_max']

    # FACES_II
    if the_scale['abbreviation'] == 'FACES_II':
        infos['the_scores'] = scoring.scoring_FACES_II(the_scale, answers)
        from myPsychology.analyzing import analyzing_FACES_II as FACES_II
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        result = FACES_II.analyzing_FACES_II(infos)
        scores['总分'] = result['total_scores']
        scores['最高分'] = result['score_max']
        scores['各维度分数'] = result['scales_scores']
        scores['各维度最高分数'] = result['scales_scores_max']

    # FIS
    if the_scale['abbreviation'] == 'FIS':
        infos['the_scores'] = scoring.scoring_FIS(the_scale, answers)
        from myPsychology.analyzing import analyzing_FIS as FIS
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        result = FIS.analyzing_FIS(infos)
        scores['总分'] = result['total_scores']
        scores['最高分'] = result['score_max']
        scores['各维度分数'] = result['scales_scores']
        scores['各维度最高分数'] = result['scales_scores_max']

    # FNE_R
    if the_scale['abbreviation'] == 'FNE_R':
        infos['the_scores'] = scoring.scoring_FNE_R(the_scale, answers)
        from myPsychology.analyzing import analyzing_FNE_R as FNE_R
        result = FNE_R.analyzing_FNE_R(infos)
        scores['总分'] = result['total_scores']
        scores['总分百分位'] = result['P_total_scores']
        scores['最高分'] = result['score_max']

    # FPQ_CR_B
    if the_scale['abbreviation'] == 'FPQ_CR_B':
        infos['the_scores'] = scoring.scoring_FPQ_CR_B(the_scale, answers)
        from myPsychology.analyzing import analyzing_FPQ_CR_B as FPQ_CR_B
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        infos['factors_scales'] = the_scale['contents']['factors_scales']
        result = FPQ_CR_B.analyzing_FPQ_CR_B(infos)
        scores['总分'] = result['total_scores']
        scores['最高分'] = result['score_max']
        scores['各维度分数'] = result['scales_scores']
        scores['各维度分数百分位'] = result['P_scales_scores']
        scores['各因子分数'] = result['factors_scores']
        scores['各因子分数百分位'] = result['P_factors_scores']
        scores['各维度最高分数'] = result['scales_scores_max']
        scores['各因子最高分数'] = result['factors_scores_max']

    # GAEQ
    if the_scale['abbreviation'] == 'GAEQ':
        infos['the_scores'] = scoring.scoring_GAEQ(the_scale, answers)
        from myPsychology.analyzing import analyzing_GAEQ as GAEQ
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        infos['factors_scales'] = the_scale['contents']['factors_scales']
        result = GAEQ.analyzing_GAEQ(infos)
        scores['总分'] = result['total_scores']
        scores['最高分'] = result['score_max']
        scores['各维度分数'] = result['scales_scores']
        scores['各维度分数百分位'] = result['P_scales_scores']
        scores['各因子分数'] = result['factors_scores']
        scores['各维度最高分数'] = result['scales_scores_max']
        scores['各因子最高分数'] = result['factors_scores_max']

    # GCQ
    if the_scale['abbreviation'] == 'GCQ':
        infos['the_scores'] = scoring.scoring_GCQ(the_scale, answers)
        from myPsychology.analyzing import analyzing_GCQ as GCQ
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        result = GCQ.analyzing_GCQ(infos)
        scores['总分'] = result['total_scores']
        scores['最高分'] = result['score_max']
        scores['各维度分数'] = result['scales_scores']
        scores['各维度最高分数'] = result['scales_scores_max']

    # GDS
    if the_scale['abbreviation'] == 'GDS':
        infos['the_scores'] = scoring.scoring_GDS(the_scale, answers)
        from myPsychology.analyzing import analyzing_GDS as GDS
        result = GDS.analyzing_GDS(infos)
        scores['总分'] = result['total_scores']
        scores['最高分'] = result['score_max']

    # HAD
    if the_scale['abbreviation'] == 'HAD':
        infos['the_scores'] = scoring.scoring_HAD(the_scale, answers)
        from myPsychology.analyzing import analyzing_HAD as HAD
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        result = HAD.analyzing_HAD(infos)
        scores['总分'] = result['total_scores']
        scores['最高分'] = result['score_max']
        scores['各维度分数'] = result['scales_scores']
        scores['各维度最高分数'] = result['scales_scores_max']

    # HAMA
    if the_scale['abbreviation'] == 'HAMA':
        infos['the_scores'] = scoring.scoring_HAMA(the_scale, answers)
        from myPsychology.analyzing import analyzing_HAMA as HAMA
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        result = HAMA.analyzing_HAMA(infos)
        scores['总分'] = result['total_scores']
        scores['最高分'] = result['score_max']
        scores['各维度分数'] = result['scales_scores']
        scores['各维度最高分数'] = result['scales_scores_max']

    # HAMD
    if the_scale['abbreviation'] == 'HAMD':
        infos['the_scores'] = scoring.scoring_HAMD(the_scale, answers)
        from myPsychology.analyzing import analyzing_HAMD as HAMD
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        result = HAMD.analyzing_HAMD(infos)
        scores['总分'] = result['total_scores']
        scores['最高分'] = result['score_max']
        scores['各维度分数'] = result['scales_scores']
        scores['各维度最高分数'] = result['scales_scores_max']

    # HCL_32
    if the_scale['abbreviation'] == 'HCL_32':
        infos['the_scores'] = scoring.scoring_HCL_32(the_scale, answers)
        from myPsychology.analyzing import analyzing_HCL_32 as HCL_32
        result = HCL_32.analyzing_HCL_32(infos)
        scores['总分'] = result['total_scores']
        scores['最高分'] = result['score_max']

    # IADDS_MSS
    if the_scale['abbreviation'] == 'IADDS_MSS':
        infos['the_scores'] = scoring.scoring_IADDS_MSS(the_scale, answers)
        from myPsychology.analyzing import analyzing_IADDS_MSS as IADDS_MSS
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        result = IADDS_MSS.analyzing_IADDS_MSS(infos)
        scores['总分'] = result['total_scores']
        scores['最高分'] = result['score_max']
        scores['各维度分数'] = result['scales_scores']
        scores['各维度最高分数'] = result['scales_scores_max']

    # ISLQ
    if the_scale['abbreviation'] == 'ISLQ':
        infos['the_scores'] = scoring.scoring_ISLQ(the_scale, answers)
        from myPsychology.analyzing import analyzing_ISLQ as ISLQ
        if the_answers['gender'] == Gender.MALE:
            infos['gender'] = Gender.MALE.value
        else:
            infos['gender'] = Gender.FEMALE.value
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        infos['factors_scales'] = the_scale['contents']['factors_scales']
        result = ISLQ.analyzing_ISLQ(infos)
        scores['总分'] = result['total_scores']
        scores['总分T值'] = result['T_total_scores']
        scores['总分百分位'] = result['P_total_scores']
        scores['各维度分数'] = result['scales_scores']
        scores['各维度分数T值'] = result['T_scales_scores']
        scores['各维度分数百分位'] = result['P_scales_scores']
        scores['各因子分数'] = result['factors_scores']
        scores['各因子分数T值'] = result['T_factors_scores']
        scores['各因子分数百分位'] = result['P_factors_scores']
        scores['最高分'] = result['score_max']
        scores['各维度最高分数'] = result['scales_scores_max']
        scores['各因子最高分数'] = result['factors_scores_max']

    # ITS
    if the_scale['abbreviation'] == 'ITS':
        infos['the_scores'] = scoring.scoring_ITS(the_scale, answers)
        from myPsychology.analyzing import analyzing_ITS as ITS
        result = ITS.analyzing_ITS(infos)
        scores['总分'] = result['total_scores']
        scores['最高分'] = result['score_max']

    # JWS
    if the_scale['abbreviation'] == 'JWS':
        infos['the_scores'] = scoring.scoring_JWS(the_scale, answers)
        from myPsychology.analyzing import analyzing_JWS as JWS
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        result = JWS.analyzing_JWS(infos)
        scores['总分'] = result['total_scores']
        scores['最高分'] = result['score_max']
        scores['各维度分数'] = result['scales_scores']
        scores['各维度最高分数'] = result['scales_scores_max']

    # LAIS
    if the_scale['abbreviation'] == 'LAIS':
        infos['the_scores'] = scoring.scoring_LAIS(the_scale, answers)
        from myPsychology.analyzing import analyzing_LAIS as LAIS
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        result = LAIS.analyzing_LAIS(infos)
        scores['总分'] = result['total_scores']
        scores['最高分'] = result['score_max']
        scores['各维度分数'] = result['scales_scores']
        scores['各维度最高分数'] = result['scales_scores_max']

    # LES
    if the_scale['abbreviation'] == 'LES':
        infos['the_scores'] = scoring.scoring_LES(the_scale, answers)
        from myPsychology.analyzing import analyzing_LES as LES
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        result = LES.analyzing_LES(infos)
        scores['事件刺激量'] = result['items_stimulus']
        scores['事件总刺激量'] = result['total_stimulus']
        scores['正性事件刺激量'] = result['stimulus_plus']
        scores['负性事件刺激量'] = result['stimulus_minus']
        scores['各维度事件刺激量'] = result['scales_stimulus']

    # LMQ_CS
    if the_scale['abbreviation'] == 'LMQ_CS':
        infos['the_scores'] = scoring.scoring_LMQ_CS(the_scale, answers)
        from myPsychology.analyzing import analyzing_LMQ_CS as LMQ_CS
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        result = LMQ_CS.analyzing_LMQ_CS(infos)
        scores['总分'] = result['total_scores']
        scores['最高分'] = result['score_max']
        scores['各维度分数'] = result['scales_scores']
        scores['各维度最高分数'] = result['scales_scores_max']

    # LSSMSS
    if the_scale['abbreviation'] == 'LSSMSS':
        infos['the_scores'] = scoring.scoring_LSSMSS(the_scale, answers)
        from myPsychology.analyzing import analyzing_LSSMSS as LSSMSS
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        result = LSSMSS.analyzing_LSSMSS(infos)
        scores['事件刺激量'] = result['items_stimulus']
        scores['事件总刺激量'] = result['total_stimulus']
        scores['正性事件刺激量'] = result['stimulus_plus']
        scores['中性事件刺激量'] = result['stimulus_zero']
        scores['负性事件刺激量'] = result['stimulus_minus']
        scores['各维度事件刺激量'] = result['scales_stimulus']

    # MDQ
    if the_scale['abbreviation'] == 'MDQ':
        infos['the_scores'] = scoring.scoring_MDQ(the_scale, answers)
        from myPsychology.analyzing import analyzing_MDQ as MDQ
        infos['rating'] = the_scale['contents']['rating']
        result = MDQ.analyzing_MDQ(infos)
        scores['总分'] = result['total_scores']
        scores['最高分'] = result['score_max']
        scores['MDQ'] = result['MDQ']

    # MHS_CA
    if the_scale['abbreviation'] == 'MHS_CA':
        infos['the_scores'] = scoring.scoring_MHS_CA(the_scale, answers)
        from myPsychology.analyzing import analyzing_MHS_CA as MHS_CA
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        result = MHS_CA.analyzing_MHS_CA(infos)
        scores['总分'] = result['total_scores']
        scores['最高分'] = result['score_max']
        scores['各维度分数'] = result['scales_scores']
        scores['各维度最高分数'] = result['scales_scores_max']
        scores['心理健康状态'] = result['scales_states']

    # MPS
    if the_scale['abbreviation'] == 'MPS':
        infos['the_scores'] = scoring.scoring_MPS(the_scale, answers)
        from myPsychology.analyzing import analyzing_MPS as MPS
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        infos['factors_scales'] = the_scale['contents']['factors_scales']
        result = MPS.analyzing_MPS(infos)
        scores['总分'] = result['total_scores']
        scores['最高分'] = result['score_max']
        scores['各维度分数'] = result['scales_scores']
        scores['各维度分数百分位'] = result['P_scales_scores']
        scores['各因子分数'] = result['factors_scores']
        scores['各因子分数百分位'] = result['P_factors_scores']
        scores['各维度最高分数'] = result['scales_scores_max']
        scores['各因子最高分数'] = result['factors_scores_max']
        scores['MPS分类器'] = result['classifier']

    # MSCPOR correction
    if the_scale['abbreviation'] == 'MSCPOR':
        infos['the_scores'] = scoring.scoring_MSCPOR(the_scale, answers)
        from myPsychology.analyzing import analyzing_MSCPOR as MSCPOR
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        result = MSCPOR.analyzing_MSCPOR(infos)
        scores['总分'] = result['total_scores']
        scores['各维度分数'] = result['scales_scores']
        scores['最高分'] = result['score_max']
        scores['各维度最高分数'] = result['scales_scores_max']

    # MTGPS
    if the_scale['abbreviation'] == 'MTGPS':
        infos['the_scores'] = scoring.scoring_MTGPS(the_scale, answers)
        from myPsychology.analyzing import analyzing_MTGPS as MTGPS
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        infos['factors_scales'] = the_scale['contents']['factors_scales']
        result = MTGPS.analyzing_MTGPS(infos)
        scores['总分'] = result['total_scores']
        scores['各维度分数'] = result['scales_scores']
        scores['各因子分数'] = result['factors_scores']
        scores['最高分'] = result['score_max']
        scores['各维度最高分数'] = result['scales_scores_max']
        scores['各因子最高分数'] = result['factors_scores_max']

    # MUNSH
    if the_scale['abbreviation'] == 'MUNSH':
        infos['the_scores'] = scoring.scoring_MUNSH(the_scale, answers)
        from myPsychology.analyzing import analyzing_MUNSH as MUNSH
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        result = MUNSH.analyzing_MUNSH(infos)
        scores['总分'] = result['total_scores']
        scores['各维度分数'] = result['scales_scores']
        scores['最高分'] = result['score_max']
        scores['各维度最高分数'] = result['scales_scores_max']

    # N_BPRS
    if the_scale['abbreviation'] == 'N_BPRS':
        infos['the_scores'] = scoring.scoring_N_BPRS(the_scale, answers)
        from myPsychology.analyzing import analyzing_N_BPRS as N_BPRS
        infos['items'] = the_scale['contents']['items']
        result = N_BPRS.analyzing_N_BPRS(infos)
        scores['总分'] = result['total_scores']
        scores['症状'] = result['items']
        scores['症状分数'] = result['items_scores']
        scores['最高分'] = result['score_max']

    # NOSIE
    if the_scale['abbreviation'] == 'NOSIE':
        infos['the_scores'] = scoring.scoring_NOSIE(the_scale, answers)
        from myPsychology.analyzing import analyzing_NOSIE as NOSIE
        result = NOSIE.analyzing_NOSIE(infos)
        scores['总分'] = result['total_scores']
        scores['各维度分数'] = result['scales_scores']
        scores['各因子分数'] = result['factors_scores']

    # NPI_Q
    if the_scale['abbreviation'] == 'NPI_Q':
        infos['the_scores'] = scoring.scoring_NPI_Q(the_scale, answers)
        from myPsychology.analyzing import analyzing_NPI_Q as NPI_Q
        infos['items'] = the_scale['contents']['items']
        result = NPI_Q.analyzing_NPI_Q(infos)
        scores['总分'] = result['total_scores']
        scores['症状'] = result['items']
        scores['各症状严重度分数'] = result['severity']
        scores['各症状苦恼程度分数'] = result['distress']

    # OCSI_U
    if the_scale['abbreviation'] == 'OCSI_U':
        infos['the_scores'] = scoring.scoring_OCSI_U(the_scale, answers)
        from myPsychology.analyzing import analyzing_OCSI_U as OCSI_U
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        result = OCSI_U.analyzing_OCSI_U(infos)
        scores['总分'] = result['total_scores']
        scores['各维度分数'] = result['scales_scores']
        scores['最高分'] = result['score_max']
        scores['各维度最高分数'] = result['scales_scores_max']

    # ODGS
    if the_scale['abbreviation'] == 'ODGS':
        infos['the_scores'] = scoring.scoring_ODGS(the_scale, answers)
        from myPsychology.analyzing import analyzing_ODGS as ODGS
        infos['scales_items'] = the_scale['contents']['scales_items']
        result = ODGS.analyzing_ODGS(infos)
        scores['总分'] = result['total_scores']
        scores['各维度分数'] = result['scales_scores']
        scores['最高分'] = result['score_max']
        scores['各维度最高分数'] = result['scales_scores_max']

    # PANSS
    if the_scale['abbreviation'] == 'PANSS':
        infos['the_scores'] = scoring.scoring_PANSS(the_scale, answers)
        from myPsychology.analyzing import analyzing_PANSS as PANSS
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        result = PANSS.analyzing_PANSS(infos)
        scores['总分'] = result['total_scores']
        scores['各维度分数'] = result['scales_scores']
        scores['最高分'] = result['score_max']
        scores['各维度最高分数'] = result['scales_scores_max']

    # PAS
    if the_scale['abbreviation'] == 'PAS':
        sub_scales = the_scale['contents']
        infos['the_scores'] = scoring.scoring_PAS(sub_scales, answers)
        from myPsychology.analyzing import analyzing_PAS as PAS
        infos['sub_scales'] = sub_scales
        result = PAS.analyzing_PAS(infos)
        scores['总分'] = result['total_scores']
        scores['最高分'] = result['score_max']

    # PCL
    if the_scale['abbreviation'] == 'PCL':
        infos['the_scores'] = scoring.scoring_PCL(the_scale, answers)
        from myPsychology.analyzing import analyzing_PCL as PCL
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        result = PCL.analyzing_PCL(infos)
        scores['总分'] = result['total_scores']
        scores['各维度分数'] = result['scales_scores']
        scores['最高分'] = result['score_max']
        scores['各维度最高分数'] = result['scales_scores_max']

    # PDQ
    if the_scale['abbreviation'] == 'PDQ':
        infos['the_scores'] = scoring.scoring_PDQ(the_scale, answers)
        from myPsychology.analyzing import analyzing_PDQ as PDQ
        coverup_items = the_scale['contents']['coverup_items']
        doubt_items = the_scale['contents']['doubt_items']
        contradictory_items = the_scale['contents']['contradictory_items']
        scales_definition = the_scale['contents']['scales_definition']
        infos['coverup_items'] = coverup_items
        infos['doubt_items'] = doubt_items
        infos['contradictory_items'] = contradictory_items
        infos['scales_definition'] = scales_definition
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        result = PDQ.analyzing_PDQ(infos)
        scores['总分'] = result['total_scores']
        scores['各维度分数'] = result['scales_scores']
        scores['最高分'] = result['score_max']
        scores['各维度最高分数'] = result['scales_scores_max']
        scores['掩饰分'] = result['coverup_scores']
        scores['怀疑分'] = result['doubt_scores']
        scores['矛盾题，对'] = result['contradictory_scores']
        scores['各维度定义'] = result['scales_definition']
        scores['划界分'] = result['cutoff_scores']

    # PDSS
    if the_scale['abbreviation'] == 'PDSS':
        infos['the_scores'] = scoring.scoring_PDSS(the_scale, answers)
        from myPsychology.analyzing import analyzing_PDSS as PDSS
        result = PDSS.analyzing_PDSS(infos)
        scores['总分'] = result['total_scores']
        scores['最高分'] = result['score_max']

    # PES
    if the_scale['abbreviation'] == 'PES':
        infos['the_scores'] = scoring.scoring_PES(the_scale, answers)
        from myPsychology.analyzing import analyzing_PES as PES
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        result = PES.analyzing_PES(infos)
        scores['总分'] = result['total_scores']
        scores['各维度分数'] = result['scales_scores']
        scores['最高分'] = result['score_max']
        scores['各维度最高分数'] = result['scales_scores_max']

    # PHCSS
    if the_scale['abbreviation'] == 'PHCSS':
        infos['the_scores'] = scoring.scoring_PHCSS(the_scale, answers)
        from myPsychology.analyzing import analyzing_PHCSS as PHCSS
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        result = PHCSS.analyzing_PHCSS(infos)
        scores['总分'] = result['total_scores']
        scores['总分百分位'] = result['P_total_scores']
        scores['各维度分数'] = result['scales_scores']
        scores['各维度分数百分位'] = result['P_scales_scores']
        scores['最高分'] = result['score_max']
        scores['各维度最高分数'] = result['scales_scores_max']

    # PHSCS
    if the_scale['abbreviation'] == 'PHSCS':
        infos['the_scores'] = scoring.scoring_PHSCS(the_scale, answers)
        from myPsychology.analyzing import analyzing_PHSCS as PHSCS
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        result = PHSCS.analyzing_PHSCS(infos)
        scores['总分'] = result['total_scores']
        scores['各维度分数'] = result['scales_scores']
        scores['最高分'] = result['score_max']
        scores['各维度最高分数'] = result['scales_scores_max']

    # PRCA
    if the_scale['abbreviation'] == 'PRCA':
        sub_answers = the_answers['sub_answers']
        infos['the_scores'] = scoring.scoring_PRCA(
            the_scale, answers, sub_answers)
        from myPsychology.analyzing import analyzing_PRCA as PRCA
        sub_score_rules = the_scale['contents']['sub_score_rules']
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        infos['sub_score_rules'] = sub_score_rules
        result = PRCA.analyzing_PRCA(infos)
        scores['总分'] = result['total_scores']
        scores['各维度分数'] = result['scales_scores']
        scores['最高分'] = result['score_max']
        scores['各维度最高分数'] = result['scales_scores_max']

    # PRS
    if the_scale['abbreviation'] == 'PRS':
        infos['the_scores'] = scoring.scoring_PRS(the_scale, answers)
        from myPsychology.analyzing import analyzing_PRS as PRS
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        result = PRS.analyzing_PRS(infos)
        scores['总分'] = result['total_scores']
        scores['各维度分数'] = result['scales_scores']
        scores['最高分'] = result['score_max']
        scores['各维度最高分数'] = result['scales_scores_max']

    # PSAI
    if the_scale['abbreviation'] == 'PSAI':
        infos['the_scores'] = scoring.scoring_PSAI(the_scale, answers)
        from myPsychology.analyzing import analyzing_PSAI as PSAI
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        if the_answers['gender'] == Gender.MALE:
            infos['gender'] = Gender.MALE.value
        else:
            infos['gender'] = Gender.FEMALE.value
        result = PSAI.analyzing_PSAI(infos)
        scores['总分'] = result['total_scores']
        scores['总分百分位'] = result['P_total_scores']
        scores['各维度分数'] = result['scales_scores']
        scores['各维度最高分数'] = result['scales_scores_max']

    # PSCI_M
    if the_scale['abbreviation'] == 'PSCI_M':
        infos['the_scores'] = scoring.scoring_PSCI_M(the_scale, answers)
        from myPsychology.analyzing import analyzing_PSCI_M as PSCI_M
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        result = PSCI_M.analyzing_PSCI_M(infos)
        scores['总分'] = result['total_scores']
        scores['各维度分数'] = result['scales_scores']
        scores['最高分'] = result['score_max']
        scores['各维度最高分数'] = result['scales_scores_max']

    # PSSCSL
    if the_scale['abbreviation'] == 'PSSCSL':
        infos['the_scores'] = scoring.scoring_PSSCSL(the_scale, answers)
        from myPsychology.analyzing import analyzing_PSSCSL as PSSCSL
        result = PSSCSL.analyzing_PSSCSL(infos)
        scores['总分'] = result['total_scores']
        scores['各维度分数'] = result['scales_scores']
        scores['最高分'] = result['score_max']
        scores['各维度最高分数'] = result['scales_scores_max']
        scores['分类器'] = result['the_classifier']

    # PTSMS
    if the_scale['abbreviation'] == 'PTSMS':
        infos['the_scores'] = scoring.scoring_PTSMS(the_scale, answers)
        from myPsychology.analyzing import analyzing_PTSMS as PTSMS
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        result = PTSMS.analyzing_PTSMS(infos)
        scores['总分'] = result['total_scores']
        scores['各维度分数'] = result['scales_scores']
        scores['最高分'] = result['score_max']
        scores['各维度最高分数'] = result['scales_scores_max']
        scores['划界分'] = result['cutoff_scores']

    # QDV
    if the_scale['abbreviation'] == 'QDV':
        infos['the_scores'] = scoring.scoring_QDV(the_scale, answers)
        from myPsychology.analyzing import analyzing_QDV as QDV
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        result = QDV.analyzing_QDV(infos)
        scores['总分'] = result['total_scores']
        scores['各维度分数'] = result['scales_scores']
        scores['最高分'] = result['score_max']
        scores['各维度最高分数'] = result['scales_scores_max']

    # QLSCA
    if the_scale['abbreviation'] == 'QLSCA':
        infos['the_scores'] = scoring.scoring_QLSCA(the_scale, answers)
        from myPsychology.analyzing import analyzing_QLSCA as QLSCA
        infos['age'] = the_answers['age']
        if the_answers['gender'] == Gender.MALE:
            infos['gender'] = Gender.MALE.value
        else:
            infos['gender'] = Gender.FEMALE.value
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        infos['factors_scales'] = the_scale['contents']['factors_scales']
        result = QLSCA.analyzing_QLSCA(infos)
        scores['总分'] = result['total_scores']
        scores['总分百分位'] = result['P_total_scores']
        scores['总分T值'] = result['T_total_scores']
        scores['各维度分数'] = result['scales_scores']
        scores['各维度分数百分位'] = result['P_scales_scores']
        scores['各维度分数T值'] = result['T_scales_scores']
        scores['各因子分数'] = result['factors_scores']
        scores['最高分'] = result['score_max']
        scores['各维度最高分数'] = result['scales_scores_max']
        scores['各因子最高分数'] = result['factors_scores_max']

    # QMPCAS_JMS
    if the_scale['abbreviation'] == 'QMPCAS_JMS':
        infos['the_scores'] = scoring.scoring_QMPCAS_JMS(the_scale, answers)
        from myPsychology.analyzing import analyzing_QMPCAS_JMS as QMPCAS_JMS
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        result = QMPCAS_JMS.analyzing_QMPCAS_JMS(infos)
        scores['总分'] = result['total_scores']
        scores['各维度分数'] = result['scales_scores']
        scores['最高分'] = result['score_max']
        scores['各维度最高分数'] = result['scales_scores_max']

    # QSCAMS
    if the_scale['abbreviation'] == 'QSCAMS':
        infos['the_scores'] = scoring.scoring_QSCAMS(the_scale, answers)
        from myPsychology.analyzing import analyzing_QSCAMS as QSCAMS
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        result = QSCAMS.analyzing_QSCAMS(infos)
        scores['总分'] = result['total_scores']
        scores['总分均值'] = result['total_scores_mean']
        scores['各维度分数'] = result['scales_scores']
        scores['各维度分数均值'] = result['scales_scores_mean']
        scores['最高分'] = result['score_max']
        scores['各维度最高分数'] = result['scales_scores_max']

    # RSES
    if the_scale['abbreviation'] == 'RSES':
        infos['the_scores'] = scoring.scoring_RSES(the_scale, answers)
        from myPsychology.analyzing import analyzing_RSES as RSES
        result = RSES.analyzing_RSES(infos)
        scores['总分'] = result['total_scores']
        scores['最高分'] = result['score_max']

    # RSESE
    if the_scale['abbreviation'] == 'RSESE':
        infos['the_scores'] = scoring.scoring_RSESE(the_scale, answers)
        from myPsychology.analyzing import analyzing_RSESE as RSESE
        infos['symptoms'] = the_scale['contents']['symptoms']
        result = RSESE.analyzing_RSESE(infos)
        scores['总分'] = result['total_scores']
        scores['症状'] = result['symptoms']
        scores['症状分数'] = result['items_scores']
        scores['最高分'] = result['score_max']

    # SAD
    if the_scale['abbreviation'] == 'SAD':
        infos['the_scores'] = scoring.scoring_SAD(the_scale, answers)
        from myPsychology.analyzing import analyzing_SAD as SAD
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        result = SAD.analyzing_SAD(infos)
        scores['总分'] = result['total_scores']
        scores['各维度分数'] = result['scales_scores']
        scores['最高分'] = result['score_max']
        scores['各维度最高分数'] = result['scales_scores_max']

    # SAQ
    if the_scale['abbreviation'] == 'SAQ':
        infos['the_scores'] = scoring.scoring_SAQ(the_scale, answers)
        from myPsychology.analyzing import analyzing_SAQ as SAQ
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        result = SAQ.analyzing_SAQ(infos)
        scores['总分'] = result['total_scores']
        scores['总分均值'] = result['total_scores_mean']
        scores['各维度分数'] = result['scales_scores']
        scores['各维度分数均值'] = result['scales_scores_mean']
        scores['最高分'] = result['score_max']
        scores['各维度最高分数'] = result['scales_scores_max']

    # SAS
    if the_scale['abbreviation'] == 'SAS':
        infos['the_scores'] = scoring.scoring_SAS(the_scale, answers)
        from myPsychology.analyzing import analyzing_SAS as SAS
        result = SAS.analyzing_SAS(infos)
        scores['总分'] = result['total_scores']
        scores['标准总分'] = result['index_score']
        scores['标准划界分'] = result['cutoff_score']
        scores['最高分'] = result['score_max']

    # SASC
    if the_scale['abbreviation'] == 'SASC':
        infos['the_scores'] = scoring.scoring_SASC(the_scale, answers)
        from myPsychology.analyzing import analyzing_SASC as SASC
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        result = SASC.analyzing_SASC(infos)
        scores['总分'] = result['total_scores']
        scores['各维度分数'] = result['scales_scores']
        scores['最高分'] = result['score_max']
        scores['各维度最高分数'] = result['scales_scores_max']

    # SBS
    if the_scale['abbreviation'] == 'SBS':
        infos['the_scores'] = scoring.scoring_SBS(the_scale, answers)
        from myPsychology.analyzing import analyzing_SBS as SBS
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        result = SBS.analyzing_SBS(infos)
        scores['总分'] = result['total_scores']
        scores['各维度分数'] = result['scales_scores']
        scores['各维度分数百分位'] = result['P_scales_scores']
        scores['最高分'] = result['score_max']
        scores['各维度最高分数'] = result['scales_scores_max']

    # SCARED
    if the_scale['abbreviation'] == 'SCARED':
        infos['the_scores'] = scoring.scoring_SCARED(the_scale, answers)
        from myPsychology.analyzing import analyzing_SCARED as SCARED
        infos['age'] = the_answers['age']
        if the_answers['gender'] == Gender.MALE:
            infos['gender'] = Gender.MALE.value
        else:
            infos['gender'] = Gender.FEMALE.value
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        result = SCARED.analyzing_SCARED(infos)
        scores['总分'] = result['total_scores']
        scores['总分百分位'] = result['P_total_scores']
        scores['各维度分数'] = result['scales_scores']
        scores['各维度分数百分位'] = result['P_scales_scores']
        scores['最高分'] = result['score_max']
        scores['各维度最高分数'] = result['scales_scores_max']

    # SCL_90
    if the_scale['abbreviation'] == 'SCL_90':
        infos['the_scores'] = scoring.scoring_SCL_90(the_scale, answers)
        from myPsychology.analyzing import analyzing_SCL_90 as SCL_90
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        result = SCL_90.analyzing_SCL_90(infos)
        scores['总分'] = result['total_scores']
        scores['总分百分位'] = result['P_total_scores']
        scores['阳性项数目'] = result['positive_items']
        scores['各维度分数'] = result['scales_scores']
        scores['各维度分数均值'] = result['scales_scores_mean']
        scores['各维度分数均值百分位'] = result['P_scales_scores_mean']
        scores['最高分'] = result['score_max']
        scores['各维度最高分数'] = result['scales_scores_max']

    # SCSQ
    if the_scale['abbreviation'] == 'SCSQ':
        infos['the_scores'] = scoring.scoring_SCSQ(the_scale, answers)
        from myPsychology.analyzing import analyzing_SCSQ as SCSQ
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        result = SCSQ.analyzing_SCSQ(infos)
        scores['总分'] = result['total_scores']
        scores['各维度分数'] = result['scales_scores']
        scores['最高分'] = result['score_max']
        scores['各维度最高分数'] = result['scales_scores_max']
        scores['各维度分数均值的Z分数'] = result['Z_scales_scores_mean']
        scores['应对方式'] = result['coping_style']

    # SDLRS
    if the_scale['abbreviation'] == 'SDLRS':
        infos['the_scores'] = scoring.scoring_SDLRS(the_scale, answers)
        from myPsychology.analyzing import analyzing_SDLRS as SDLRS
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        result = SDLRS.analyzing_SDLRS(infos)
        scores['总分'] = result['total_scores']
        scores['各维度分数'] = result['scales_scores']
        scores['最高分'] = result['score_max']
        scores['各维度最高分数'] = result['scales_scores_max']

    # SDQ
    if the_scale['abbreviation'] == 'SDQ':
        sub_scales = the_scale['contents']
        infos['the_scores'] = scoring.scoring_SDQ(sub_scales, answers)
        from myPsychology.analyzing import analyzing_SDQ as SDQ
        infos['sub_scales'] = sub_scales
        infos['answers'] = answers
        result = SDQ.analyzing_SDQ(infos)
        scores['评分结果'] = result

    # SDS
    if the_scale['abbreviation'] == 'SDS':
        infos['the_scores'] = scoring.scoring_SDS(the_scale, answers)
        from myPsychology.analyzing import analyzing_SDS as SDS
        result = SDS.analyzing_SDS(infos)
        scores['总分'] = result['total_scores']
        scores['总分百分位'] = result['P_total_scores']
        scores['最高分'] = result['score_max']

    # SLCS_R
    if the_scale['abbreviation'] == 'SLCS_R':
        infos['the_scores'] = scoring.scoring_SLCS_R(the_scale, answers)
        from myPsychology.analyzing import analyzing_SLCS_R as SLCS_R
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        result = SLCS_R.analyzing_SLCS_R(infos)
        scores['总分'] = result['total_scores']
        scores['各维度分数'] = result['scales_scores']
        scores['最高分'] = result['score_max']
        scores['各维度最高分数'] = result['scales_scores_max']

    # SQ
    if the_scale['abbreviation'] == 'SQ':
        infos['the_scores'] = scoring.scoring_SQ(the_scale, answers)
        from myPsychology.analyzing import analyzing_SQ as SQ
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        result = SQ.analyzing_SQ(infos)
        scores['总分'] = result['total_scores']
        scores['各维度分数'] = result['scales_scores']
        scores['最高分'] = result['score_max']
        scores['各维度最高分数'] = result['scales_scores_max']

    # SRHMS
    if the_scale['abbreviation'] == 'SRHMS':
        infos['the_scores'] = scoring.scoring_SRHMS(the_scale, answers)
        from myPsychology.analyzing import analyzing_SRHMS as SRHMS
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        infos['factors_scales'] = the_scale['contents']['factors_scales']
        result = SRHMS.analyzing_SRHMS(infos)
        scores['总分'] = result['total_scores']
        scores['各维度分数'] = result['scales_scores']
        scores['各因子分数'] = result['factors_scores']
        scores['最高分'] = result['score_max']
        scores['各维度最高分数'] = result['scales_scores_max']
        scores['各因子最高分数'] = result['factors_scores_max']

    # SRSS
    if the_scale['abbreviation'] == 'SRSS':
        infos['the_scores'] = scoring.scoring_SRSS(the_scale, answers)
        from myPsychology.analyzing import analyzing_SRSS as SRSS
        infos['Symptoms'] = the_scale['contents']['Symptoms']
        infos['score_rules'] = the_scale['contents']['score_rules']
        result = SRSS.analyzing_SRSS(infos)
        scores['总分'] = result['total_scores']
        scores['最高分'] = result['score_max']
        scores['症状'] = result['Symptoms']
        scores['症状分数'] = result['items_scores']

    # SSMSS
    if the_scale['abbreviation'] == 'SSMSS':
        infos['the_scores'] = scoring.scoring_SSMSS(the_scale, answers)
        from myPsychology.analyzing import analyzing_SSMSS as SSMSS
        if the_answers['gender'] == Gender.MALE:
            infos['gender'] = Gender.MALE.value
        else:
            infos['gender'] = Gender.FEMALE.value
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        result = SSMSS.analyzing_SSMSS(infos)
        scores['总分'] = result['total_scores']
        scores['总分百分位'] = result['P_total_scores']
        scores['各维度分数'] = result['scales_scores']
        scores['各维度分数百分位'] = result['P_scales_scores']
        scores['最高分'] = result['score_max']
        scores['各维度最高分数'] = result['scales_scores_max']

    # SSRS
    if the_scale['abbreviation'] == 'SSRS':
        infos['the_scores'] = scoring.scoring_SSRS(the_scale, answers)
        from myPsychology.analyzing import analyzing_SSRS as SSRS
        result = SSRS.analyzing_SSRS(infos)
        scores['总分'] = result['total_scores']
        scores['各维度分数'] = result['scales_scores']
        scores['最高分'] = result['score_max']
        scores['各维度最高分数'] = result['scales_scores_max']

    # STAI
    if the_scale['abbreviation'] == 'STAI':
        sub_scales = the_scale['contents']
        infos['the_scores'] = scoring.scoring_STAI(sub_scales, answers)
        from myPsychology.analyzing import analyzing_STAI as STAI
        result = STAI.analyzing_STAI(infos)
        scores['评分结果'] = result

    # TAI
    if the_scale['abbreviation'] == 'TAI':
        infos['the_scores'] = scoring.scoring_TAI(the_scale, answers)
        from myPsychology.analyzing import analyzing_TAI as TAI
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        result = TAI.analyzing_TAI(infos)
        scores['总分'] = result['total_scores']
        scores['各维度分数'] = result['scales_scores']
        scores['最高分'] = result['score_max']
        scores['各维度最高分数'] = result['scales_scores_max']
        scores['TAI状态'] = result['state_TAI']

    # TAS
    if the_scale['abbreviation'] == 'TAS':
        infos['the_scores'] = scoring.scoring_TAS(the_scale, answers)
        from myPsychology.analyzing import analyzing_TAS as TAS
        result = TAS.analyzing_TAS(infos)
        scores['总分'] = result['total_scores']
        scores['TAS指数'] = result['index_TAS']
        scores['最高分'] = result['score_max']

    # TLQ
    if the_scale['abbreviation'] == 'TLQ':
        infos['the_scores'] = scoring.scoring_TLQ(the_scale, answers)
        from myPsychology.analyzing import analyzing_TLQ as TLQ
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        result = TLQ.analyzing_TLQ(infos)
        scores['总分'] = result['total_scores']
        scores['各维度分数'] = result['scales_scores']
        scores['最高分'] = result['score_max']
        scores['各维度最高分数'] = result['scales_scores_max']

    # TSI
    if the_scale['abbreviation'] == 'TSI':
        infos['the_scores'] = scoring.scoring_TSI(the_scale, answers)
        from myPsychology.analyzing import analyzing_TSI as TSI
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        result = TSI.analyzing_TSI(infos)
        scores['总分'] = result['total_scores']
        scores['各维度分数'] = result['scales_scores']
        scores['最高分'] = result['score_max']
        scores['各维度最高分数'] = result['scales_scores_max']

    # UCLA_LS_V3
    if the_scale['abbreviation'] == 'UCLA_LS_V3':
        infos['the_scores'] = scoring.scoring_UCLA_LS_V3(the_scale, answers)
        from myPsychology.analyzing import analyzing_UCLA_LS_V3 as UCLA_LS_V3
        result = UCLA_LS_V3.analyzing_UCLA_LS_V3(infos)
        scores['总分'] = result['total_scores']
        scores['最高分'] = result['score_max']

    # UKU_SERS
    if the_scale['abbreviation'] == 'UKU_SERS':
        infos['the_scores'] = scoring.scoring_UKU_SERS(the_scale, answers)
        from myPsychology.analyzing import analyzing_UKU_SERS as UKU_SERS
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        result = UKU_SERS.analyzing_UKU_SERS(infos)
        scores['总分'] = result['total_scores']
        scores['各维度分数'] = result['scales_scores']
        scores['最高分'] = result['score_max']
        scores['各维度最高分数'] = result['scales_scores_max']

    # WFCS
    if the_scale['abbreviation'] == 'WFCS':
        infos['the_scores'] = scoring.scoring_WFCS(the_scale, answers)
        from myPsychology.analyzing import analyzing_WFCS as WFCS
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        infos['factors_scales'] = the_scale['contents']['factors_scales']
        result = WFCS.analyzing_WFCS(infos)
        scores['总分'] = result['total_scores']
        scores['各维度分数'] = result['scales_scores']
        scores['各因子分数'] = result['factors_scores']
        scores['最高分'] = result['score_max']
        scores['各维度最高分数'] = result['scales_scores_max']
        scores['各因子最高分数'] = result['factors_scores_max']

    # WQIT
    if the_scale['abbreviation'] == 'WQIT':
        infos['the_scores'] = scoring.scoring_WQIT(the_scale, answers)
        from myPsychology.analyzing import analyzing_WQIT as WQIT
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        result = WQIT.analyzing_WQIT(infos)
        scores['总分'] = result['total_scores']
        scores['各维度分数'] = result['scales_scores']
        scores['最高分'] = result['score_max']
        scores['各维度最高分数'] = result['scales_scores_max']

    # Y_BOCS
    if the_scale['abbreviation'] == 'Y_BOCS':
        infos['the_scores'] = scoring.scoring_Y_BOCS(the_scale, answers)
        from myPsychology.analyzing import analyzing_Y_BOCS as Y_BOCS
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        result = Y_BOCS.analyzing_Y_BOCS(infos)
        scores['总分'] = result['total_scores']
        scores['各维度分数'] = result['scales_scores']
        scores['最高分'] = result['score_max']
        scores['各维度最高分数'] = result['scales_scores_max']

    # YMRS
    if the_scale['abbreviation'] == 'YMRS':
        infos['the_scores'] = scoring.scoring_YMRS(the_scale, answers)
        from myPsychology.analyzing import analyzing_YMRS as YMRS
        result = YMRS.analyzing_YMRS(infos)
        scores['总分'] = result['total_scores']
        scores['最高分'] = result['score_max']

    # ZNPQ
    if the_scale['abbreviation'] == 'ZNPQ':
        infos['the_scores'] = scoring.scoring_ZNPQ(the_scale, answers)
        from myPsychology.analyzing import analyzing_ZNPQ as ZNPQ
        if the_answers['profession'] != Profession.COLLEGE:
            infos['profession'] = '成人'
        else:
            infos['profession'] = '大学生'
        infos['scales_items'] = the_scale['contents']['scales_items']
        infos['score_rules'] = the_scale['contents']['score_rules']
        result = ZNPQ.analyzing_ZNPQ(infos)
        scores['总分'] = result['total_scores']
        scores['总分百分位'] = result['P_total_scores']
        scores['各维度分数'] = result['scales_scores']
        scores['各维度分数百分位'] = result['P_scales_scores']
        scores['最高分'] = result['score_max']
        scores['各维度最高分数'] = result['scales_scores_max']

    return scores
